package com.kantboot.business.talent.domain.entity;

import com.fasterxml.jackson.annotation.JsonIdentityInfo;
import com.fasterxml.jackson.annotation.ObjectIdGenerators;
import jakarta.persistence.*;
import lombok.Getter;
import lombok.Setter;
import lombok.experimental.Accessors;
import org.hibernate.annotations.DynamicInsert;
import org.hibernate.annotations.DynamicUpdate;
import org.springframework.data.jpa.domain.support.AuditingEntityListener;

import java.io.Serializable;
import java.util.Date;

/**
 * 员工（用户）教育经历
 * 员工（用户）
 * 学校名称
 * 学历
 * 专业类别
 * 专业
 * 是否国外
 * 在读期间经历
 */
@Entity
@Getter
@Setter
@Table(name = "bus_talent_edu_experience_of_user_account")
@Accessors(chain = true)
@EntityListeners(AuditingEntityListener.class)
@DynamicUpdate
@DynamicInsert
@JsonIdentityInfo(generator = ObjectIdGenerators.PropertyGenerator.class, property = "id")
public class BusTalentEduExperienceOfUserAccount implements Serializable {

    /**
     * 主键
     */
    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    @Column(name = "id")
    private Long id;

    /**
     * 员工ID
     */
    @Column(name = "emp_id")
    private Long empId;

    /**
     * 学校名称
     */
    @Column(name = "school_name")
    private String schoolName;

    /**
     * 学历数值
     */
    @Column(name = "education_level")
    private Long educationLevel;

    /**
     * 专业编码（二级专业编码）
     */
    @Column(name = "edu_major_code", length = 32)
    private String eduMajorCode;

    /**
     * 是否国外
     */
    @Column(name = "is_foreign")
    private Boolean isForeign;

    /**
     * 入学时间
     */
    @Column(name = "gmt_start")
    private Date gmtStart;

    /**
     * 毕业时间
     */
    @Column(name = "gmt_end")
    private Date gmtEnd;

}
